Skip to main content

All Questions

4votes
2answers
484views

Vectorizing a pixel-averaging operation in Numpy

I am reading from a file containing some segments (irregular parcels of the image) and trying to average the entire segment to have one pixel value. This is the code I use: ...
shaunakde's user avatar
3votes
1answer
930views

Using Gibbs sampling to segment an image

I have been reading some NumPy guides but can't seem to figure it out. My TA told me I should be able to speed up my code by using a NumPy array instead of a for ...
marcopolo's user avatar

close